/**
 * Created with IntelliJ IDEA.
 * User: 12629
 * Date: 2022/2/23
 * Time: 20:03
 * Description:
 */
class Base {
    public int a;
    public int b;

    public void testA() {
        System.out.println("Base::testA()!");
    }

    public void testB() {
        System.out.println("Base::testB()!");
    }
}

public class Derived extends Base{
    public boolean a;
    public int c;
    public int d;

    public void testA(int a) {
        System.out.println("Derived::testA()!"+a);
    }

    //
    public static void func() {
        //super.a = 10;

    }
    public void testB() {
        super.a = 15;//默认情况下  子类的优先使用
        super.b = 20;//
        c = 30;
        d = 40;
        //f = 10;
         /* System.out.println(a+" "+b+" "+c+" "+d+"");*/
        System.out.println("Derived::testB()");
    }

    public void testC() {
        testA();
        testA(10);
        testB();
    }

    public static void main(String[] args) {
        Derived derived = new Derived();
        derived.testC();
    }
}
